#ifndef __CCUSTOM_PICTURE_CONTROL_H__
#define __CCUSTOM_PICTURE_CONTROL_H__

#include <gdiplus.h>
using namespace Gdiplus;

class CCustomPicture : public CStatic
{
	DECLARE_DYNAMIC(CCustomPicture)

//*************************************************************************************************//Class Function
public:
	CCustomPicture(void);
	~CCustomPicture(void);

	//Commom Setting
	void Initialize(HWND hPParentWnd, HWND hParentWnd, HDC hBgDC, HDC hDrawDC, int nParentx = 0, int nParenty = 0);

	//Image Setting
	void SetImage(UINT nImgID);

	//UI Drawing
	void DrawUI();
	BOOL ShowWindow(int nCmdShow);
	
	//String or Font Setting
	void CreateFont();
	void DrawText(CString strTitle1, CString strTitle2, CString strTitle3, int nTitleHilight);

//*************************************************************************************************//Class Parameters
private:
	//String and Font Parameter
	Gdiplus::Unit m_enFontUnit;
	Gdiplus::FontFamily* m_pFontFamily;
	Gdiplus::StringFormat* m_strTextFormat;
	
	int m_nFontSizeNormal, m_pFontSizeHilight, m_nFontStyleNormal, m_nFontStyleHilight;
	Gdiplus::SolidBrush* m_pBrushNormal, *m_pBrushHilight;
	Gdiplus::Font* m_pFontNormal, *m_pFontHilight;

	//UI Rect Parameter
	CRect m_rtRect, m_rtPRect, m_rtPPRect;
	
	//Image and Handle Parameter
	Image* m_pImg;
	HDC m_hBgDC, m_hDrawDC;
	HWND m_hPParentWnd, m_hParentWnd;
//*************************************************************************************************//Class Message
public:
	virtual void PreSubclassWindow();
	virtual void DrawItem(LPDRAWITEMSTRUCT /*lpDrawItemStruct*/);
	DECLARE_MESSAGE_MAP()
	afx_msg BOOL OnEraseBkgnd(CDC* pDC);
protected:
	
};
#endif

